server {
	 listen  80;  
	 server_name {{server_name}};
	 charset utf-8; #设置编码为utf-8
		 
	 #配置网站首页
	 location = / {
		root {{html_path}};
		index index.html;
	}
	 #配置静态资源访问目录
	 location ~* \.(ico|gif|jpg|jpeg|png|svg|ttf|woff|otf|eot|woff2)$ {
		gzip_static on;	#静态资源开启缓存功能
		add_header Cache-Control public;
		expires 30d;
		root {{html_path}};
	}
	 location ~* \.(html|css|js|json)$ {
		expires -1;
		add_header Cache-Control "no-store";#不开启缓存
		gzip_static on;	
		#add_header Cache-Control public;	
		#expires 30d;
		root {{html_path}};
	}
	location =/GetFile/getUploadImg {
		proxy_intercept_errors on;#开启错误码监听，不然error_page没用
		expires -1;
		add_header Cache-Control "no-store";#不开启缓存	
		proxy_pass {{proxy_pass}};
	}
	location / {
		proxy_intercept_errors on;#开启错误码监听，不然error_page没用
		expires -1;
		add_header Cache-Control "no-store";#不开启缓存	
		proxy_pass {{proxy_pass}};
	}	
	  error_page 404 /404.html;
	  error_page 500 502 503 504 403 /50x.html;
	  
	 location = /50x.html {
		root {{html_path}};
	}	
	 location = /404.html {
		root {{html_path}};
	}
}
